# Maintainer: Anatol Pomozov <anatol.pomozov@gmail.com>
# Contributor: birdflesh <antkoul at gmail dot com>
# Contributor: Natan Vivo <nvivo64_gmail_com>
# Contributor: rabyte <rabyte*gmail>
# Contributor: Simon Morgan <simon@16hz.net>

pkgname=fatsort
pkgver=1.6.5.640
pkgrel=1
pkgdesc='Sorts directory structures of FAT16 and FAT32 file systems'
arch=(loong64 x86_64)
url='http://fatsort.sourceforge.net'
license=(GPL)
depends=(glibc)
makedepends=(help2man)
#checkdepends=(dosfstools bbe)
source=(https://downloads.sourceforge.net/project/$pkgname/$pkgname-$pkgver.tar.xz)
sha256sums=('630ece56d9eb3a55524af0aec3aade7854360eba949172a6cfb4768cb8fbe42e')

build() {
  cd $pkgname-$pkgver
  make
}

check() {
  cd $pkgname-$pkgver
  # the tests require sudo so we cannot use it in a clean environment build
  # make tests
}

package() {
  cd $pkgname-$pkgver
  make DESTDIR="$pkgdir" SBINDIR=/usr/bin MANDIR=/usr/share/man/man1 install
}
